#include <iostream>
#include "SocketException.h"

using namespace std;

void throw_se ()
{
	throw SocketException("Could not connect.");
}

void throw_bc ()
{
	throw BadConnection("Bad Conn");
}

int main (void)
{
	try
	{
		throw_bc();
	}
	catch (const BadConnection& e)
	{
		cout << e.description() << endl;
		try
		{
			throw_se();
		}
		catch (const SocketException& e)
		{
			cout << e.description() << endl;
		}
	}
	return 0;
}

